package com.ruoyi.report.forms.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.report.forms.mapper.DispatchAccessDataDayMapper;
import com.ruoyi.report.forms.domain.DispatchAccessDataDay;
import com.ruoyi.report.forms.service.IDispatchAccessDataDayService;

/**
 * 接入点每日数据Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-03-05
 */
@Service
public class DispatchAccessDataDayServiceImpl implements IDispatchAccessDataDayService 
{
    @Autowired
    private DispatchAccessDataDayMapper dispatchAccessDataDayMapper;

    /**
     * 查询接入点每日数据
     * 
     * @param id 接入点每日数据主键
     * @return 接入点每日数据
     */
    @Override
    public DispatchAccessDataDay selectDispatchAccessDataDayById(String id)
    {
        return dispatchAccessDataDayMapper.selectDispatchAccessDataDayById(id);
    }

    /**
     * 查询接入点每日数据列表
     * 
     * @param dispatchAccessDataDay 接入点每日数据
     * @return 接入点每日数据
     */
    @Override
    public List<DispatchAccessDataDay> selectDispatchAccessDataDayList(DispatchAccessDataDay dispatchAccessDataDay)
    {
        return dispatchAccessDataDayMapper.selectDispatchAccessDataDayList(dispatchAccessDataDay);
    }

    /**
     * 新增接入点每日数据
     * 
     * @param dispatchAccessDataDay 接入点每日数据
     * @return 结果
     */
    @Override
    public int insertDispatchAccessDataDay(DispatchAccessDataDay dispatchAccessDataDay)
    {
        dispatchAccessDataDay.setCreateTime(DateUtils.getNowDate());
        return dispatchAccessDataDayMapper.insertDispatchAccessDataDay(dispatchAccessDataDay);
    }

    /**
     * 修改接入点每日数据
     * 
     * @param dispatchAccessDataDay 接入点每日数据
     * @return 结果
     */
    @Override
    public int updateDispatchAccessDataDay(DispatchAccessDataDay dispatchAccessDataDay)
    {
        dispatchAccessDataDay.setUpdateTime(DateUtils.getNowDate());
        return dispatchAccessDataDayMapper.updateDispatchAccessDataDay(dispatchAccessDataDay);
    }

    /**
     * 批量删除接入点每日数据
     * 
     * @param ids 需要删除的接入点每日数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchAccessDataDayByIds(String[] ids)
    {
        return dispatchAccessDataDayMapper.deleteDispatchAccessDataDayByIds(ids);
    }

    /**
     * 删除接入点每日数据信息
     * 
     * @param id 接入点每日数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchAccessDataDayById(String id)
    {
        return dispatchAccessDataDayMapper.deleteDispatchAccessDataDayById(id);
    }
}
